﻿@{
    var htmlAttributes = new Dictionary<string, object> {
        {"class", "text large"}
    };

    if (Model.Required == true) {
        htmlAttributes["required"] = "required";
    }

    if (Model.AutoFocus == true) {
        htmlAttributes["autofocus"] = "autofocus";
    }
}

@Html.TextBox("Text", (string)Model.Text, htmlAttributes)